home *** CD-ROM | disk | FTP | other *** search
/ Chip 1997 December / CHIP Turkiye Aralık 1997.iso / grafik / masterc / demo / disk1 / install.dat < prev    next >
Text File  |  1997-02-07  |  8KB  |  309 lines

  1. /* __________ DEFINE PROJECT __________ */
  2.  
  3. @DefineProject                      
  4.     @Name       = "MASTERCAM"
  5.     @Version    = "6.1"
  6.     @Subdir     = "\\MILL6"
  7.     @OutDrive   = C
  8.     @Immediate  = @TRUE
  9.     @InDiskBell = @TRUE
  10.     @Requires @HardDisk
  11.     @Group      = "EKR"
  12. @EndProject
  13.  
  14. /* __________ INSTALLATION GROUPS __________ */
  15.  
  16. /* (E) Install OpenGL Dlls  */
  17. /* (K) English units        */
  18. /* (R) INCLUDE win32s files */
  19.  
  20. /* __________ INITIALIZE VARIABLES _________ */
  21.  
  22. @DefineVars
  23.     @Qstring @IconTXT     = "Mastercam Demo6"
  24.     @Qstring @Product     = "MASTERCAM DEMO"
  25.     @Qstring @LowName     = "demo6"
  26.     @Qstring @CGroup      = ""
  27.     @Qstring @AppMItem    = ""
  28.     @Qstring @OpGLIco     = ""
  29.     @Integer @TempInt     = -1
  30. @EndVars
  31.  
  32. /* __________ DEFAULT NUMBER OF DISKS __________ */
  33.  
  34. @NumberOfDisks = 9         /* (8-2) + (3 Win32s) */
  35.  
  36. /* __________ CHECK WINDOWS VERSION __________ */
  37.  
  38. @If (@WinMajor == 3 && @WinMinor >= 95)             // Windows 95
  39.     @NumberOfDisks = 6
  40.     @ClearGroup(R)
  41. @EndIf
  42.  
  43. @If (@WinMajor == 4)                                // Windows 95
  44.     @NumberOfDisks = 6
  45.     @ClearGroup(R)
  46. @EndIf
  47.  
  48. @If ("@GetEnv("OS")" == "Windows_NT")               // Windows NT
  49.     @NumberOfDisks = 6
  50.     @ClearGroup(R)
  51. @EndIf
  52.  
  53. /* __________ SAY HELLO __________ */
  54.  
  55. @Display
  56.     @Cls
  57.     This program will install @Product version @Version on your computer.
  58.     You may press the [Esc] key at any time to abort the installation.
  59.  
  60.     Each question has a default answer.  If the default answer is
  61.     correct, press the [ENTER] key in response to the question.
  62.     Otherwise, type the answer and then press the [ENTER] key.
  63.  
  64.     If you make a mistake while typing, press the [BACKSPACE] key
  65.     and then retype the answer.
  66.     @Pause
  67.  
  68. @EndDisplay
  69.  
  70. /* __________ GET DRIVE __________ */
  71.  
  72. @GetOutDrive
  73.     @Cls
  74.     Select target drive for @Product ...
  75.     @DlgCtrlSize(0,3,2,8,30)
  76.     @Suppress(0,17)
  77. @EndOutDrive
  78.  
  79. /* __________ GET DIRECTORY __________ */
  80.  
  81. NEWDIR:
  82. @Subdir = "\\DEMO6"
  83. @GetSubdir
  84.     @Cls
  85.     Specify directory on target drive @OutDrive ...
  86.     @DlgCtrlSize(0,3,2,4,30)
  87. @EndSubdir
  88.  
  89. /* __________ REMOVE DRIVE - IF ENTERED __________ */
  90.  
  91. @TempInt = @StrFind ("@SubDir", ":")
  92. @If (@TempInt >= 0)
  93.     @SubDir = "@StrDel ("@SubDir", 0, (@TempInt+1))"
  94. @EndIf
  95.  
  96. /* __________ REMOVE PERIOD - IF ENTERED __________ */
  97.  
  98. @TempInt = @StrFind ("@SubDir", ".")
  99. @If (@TempInt >= 0)
  100.     @Display
  101.         MASTERCAM products do not support
  102.         directories which contain periods.
  103.  
  104.         Please select another directory.
  105.         @Pause
  106.     @EndDisplay
  107.     @GOTO NEWDIR
  108. @EndIf
  109.  
  110. /* __________ VERIFY INFORMATION __________ */
  111.  
  112. @Display
  113.     @Cls
  114.     Please verify installation information ...
  115.  
  116.     Product:
  117.     @Product version @Version
  118.  
  119.     Destination:
  120.     @OutDrive:@SubDir
  121.     @Pause
  122. @EndDisplay
  123.  
  124. /* __________ ASK FOR DEFAULT UNITS __________ */
  125.  
  126. @GetOption
  127.     @Cls
  128.     Please select default units .....
  129.     @DlgCtrlSize(0,3,2,5,12)
  130.     @Option 100 = "English"
  131.     @Option 200 = "Metric"
  132. @EndOption
  133.  
  134. @If (200 [= @Option)
  135.     @ClearGroup(K)
  136. @EndIf
  137.  
  138. /* __________ CREATE ALL SUBDIRECTORIES __________ */
  139.  
  140. @MkDir ("@OutDrive:\\@Subdir\\ASCII")
  141. @MkDir ("@OutDrive:\\@Subdir\\BMP")
  142. @MkDir ("@OutDrive:\\@Subdir\\CADL")
  143. @MkDir ("@OutDrive:\\@Subdir\\DWG")
  144. @MkDir ("@OutDrive:\\@Subdir\\DXF")
  145. @MkDir ("@OutDrive:\\@Subdir\\GE3")
  146. @MkDir ("@OutDrive:\\@Subdir\\GEO")
  147. @MkDir ("@OutDrive:\\@Subdir\\ICONS")
  148. @MkDir ("@OutDrive:\\@Subdir\\IGES")
  149. @MkDir ("@OutDrive:\\@Subdir\\MACROS")
  150. @MkDir ("@OutDrive:\\@Subdir\\MTOOLS")
  151. @MkDir ("@OutDrive:\\@Subdir\\NCI")
  152. @MkDir ("@OutDrive:\\@Subdir\\PIC")
  153. @MkDir ("@OutDrive:\\@Subdir\\PRM")
  154. @MkDir ("@OutDrive:\\@Subdir\\STL")
  155. @MkDir ("@OutDrive:\\@Subdir\\TEMP")
  156. @MkDir ("@OutDrive:\\@Subdir\\VDA")
  157. @MkDir ("@OutDrive:\\@Subdir\\WMF")
  158.  
  159. /* __________ APPLICATION DISK #1 __________ */
  160.  
  161. @If (5000 [= @OPTION)
  162.     @LocSuffix = "\\DISK1"
  163.     @ChDir ("@LocPrefix@LocMiddle@LocSuffix")
  164.     @Chain ("Disk #1", "DISK1.DAT")
  165. @Else
  166.     @Chain ("Disk #1", "@InDrive:\\disk1.dat")
  167. @EndIf
  168.  
  169. /* __________ APPLICATION DISK #2 or #4 __________ */
  170.  
  171. @If ('R' [! @Group)     /* Windows 95 goto disk #2 */
  172.                         /* Windows NT goto disk #2 */
  173. @If (5000 [= @OPTION)
  174.     @LocSuffix = "\\DISK2"
  175.     @ChDir ("@LocPrefix@LocMiddle@LocSuffix")
  176.     @Chain ("Disk #2", "DISK2.DAT")
  177. @Else
  178.     @Chain ("Disk #2", "@InDrive:\\disk2.dat")
  179. @EndIf
  180.  
  181. @Else                   /* Windows 31 goto disk #4 */
  182.  
  183. @If (5000 [= @OPTION)
  184.     @LocSuffix = "\\DISK4"
  185.     @ChDir ("@LocPrefix@LocMiddle@LocSuffix")
  186.     @Chain ("Disk #4", "DISK4.DAT")
  187. @Else
  188.     @Chain ("Disk #4", "@InDrive:\\disk4.dat")
  189. @EndIf
  190.  
  191. @EndIf
  192.  
  193. /* __________ APPLICATION DISK #6 __________ */
  194.  
  195. @If (5000 [= @OPTION)
  196.     @LocSuffix = "\\DISK6"
  197.     @ChDir ("@LocPrefix@LocMiddle@LocSuffix")
  198.     @Chain ("Disk #6", "DISK6.DAT")
  199. @Else
  200.     @Chain ("Disk #6", "@InDrive:\\disk6.dat")
  201. @EndIf
  202.  
  203. /* __________ APPLICATION DISK #7 __________ */
  204.  
  205. @If (5000 [= @OPTION)
  206.     @LocSuffix = "\\DISK7"
  207.     @ChDir ("@LocPrefix@LocMiddle@LocSuffix")
  208.     @Chain ("Disk #7", "DISK7.DAT")
  209. @Else
  210.     @Chain ("Disk #7", "@InDrive:\\disk7.dat")
  211. @EndIf
  212.  
  213. /* __________ APPLICATION DISK #8 __________ */
  214.  
  215. @If (5000 [= @OPTION)
  216.     @LocSuffix = "\\DISK8"
  217.     @ChDir ("@LocPrefix@LocMiddle@LocSuffix")
  218.     @Chain ("Disk #8", "DISK8.DAT")
  219. @Else
  220.     @Chain ("Disk #8", "@InDrive:\\disk8.dat")
  221. @EndIf
  222.  
  223. /* __________ UPDATE MASTERCAM.INI __________ */
  224.  
  225. @SetINI ("@LowName", "maindir", "@Outdrive:\\@Subdir", "mastrcam.ini")
  226. @If ('K' [= @Group)
  227.     @SetINI ("@LowName", "units", "E", "mastrcam.ini")
  228. @Else
  229.     @SetINI ("@LowName", "units", "M", "mastrcam.ini")
  230. @Endif
  231.  
  232. /* __________ PROMPT FOR SHADING MODE (SAVE TO MASTERCAM.INI) __________ */
  233.  
  234. @If ('R' [! @Group)                     /* 95 or NT */
  235.  
  236. //@GetOption
  237. //    @Cls
  238. //    Please specify default shading mode .....
  239. //    (see glreadme.txt for more info)
  240. //
  241. //    @DlgCtrlSize(0,4,2,6,26)
  242. //    @Option 100 = "OpenGL (recommended)"
  243. //    @Option 200 = "v6.0"
  244. //@EndOption
  245.  
  246. //@If (100 [= @Option)
  247.     @SetINI ("common", "shading", "GL", "mastrcam.ini")
  248. //@Else
  249. //    @SetINI ("common", "shading", "V6", "mastrcam.ini")
  250. //@EndIf
  251.  
  252. //@OpGLIco = "[AddItem(NOTEPAD GLREADME.TXT,glreadme.txt,,,,,@Outdrive:\\@Subdir)]"
  253.  
  254. @EndIf
  255.  
  256. /* __________ CREATE MASTERCAM GROUP __________ */
  257.  
  258. @CGroup = "[CreateGroup(Mastercam)]"
  259. @AppMItem = "[AddItem(@Outdrive:\\@Subdir\\DEMO6.EXE,@IconTXT,,,,,@Outdrive:\\@Subdir)]"
  260. @ProgramManager ("@CGroup@AppMItem@OpGLIco")
  261.  
  262. /* __________ WIN32S DISK __________ */
  263.  
  264. @If ('R' [= @Group)
  265.  
  266. @If (5000 [= @OPTION)
  267.     @ChDrive (@StartupDrive)
  268.     @ChDir ("@StartupDir")
  269. @Endif
  270.  
  271. @Display
  272.     @Cls
  273.     @Product installation complete ...
  274.    
  275.     Select OK to run Microsoft Win32s Setup.
  276.     Select CANCEL to quit.
  277.  
  278.     Installation of Win32s is required to run Mastercam.
  279.     Please select OK unless you are sure that the latest
  280.     version of Win32s has already been installed (7/95).
  281.  
  282.     @Pause
  283. @EndDisplay
  284.  
  285. @If (5000 [= @OPTION)
  286.     @LocSuffix = "\\MILL\\WIN32S1"
  287.     @ChDir ("@LocPrefix@LocSuffix")
  288.     @Chain ("Win32s Disk #1", "WIN32S1.DAT")
  289. @Else
  290.     @Chain ("Win32s Disk #1", "@InDrive:\\win32s1.dat")
  291. @EndIf
  292.  
  293. @EndIf
  294.  
  295. /* __________ RETURN TO STARTUP DIRECTORY __________ */
  296.  
  297. @If (5000 [= @OPTION)
  298.     @ChDrive (@StartupDrive)
  299.     @ChDir ("@StartupDir")
  300. @EndIf
  301.  
  302. /* __________ INSTALLATION COMPLETE __________ */
  303.  
  304. @Finish
  305.     @Cls
  306.     @Product installation complete ...
  307.     @Pause
  308. @EndFinish
  309.